import Vue from "vue";
import VueRouter from "vue-router";
import Home from "../views/Home.vue";

Vue.use(VueRouter);

const routes = [
  {
    path: "/",
    name: "Home",
    component: Home,
  },
  {
    path: "/work",
    name: "Work",
    component: () => import(/* webpackChunkName: "work" */ "../views/Work.vue"),
  },
  {
    path: "/project",
    name: "Project",
    component: () =>
      import(/* webpackChunkName: "project" */ "../views/Project.vue"),
  },
  {
    path: "/skill",
    name: "Skill",
    component: () =>
      import(/* webpackChunkName: "skill" */ "../views/Skill.vue"),
  },
  {
    path: "/education",
    name: "Education",
    component: () =>
      import(/* webpackChunkName: "education" */ "../views/Education.vue"),
  },
  {
    path: "/self",
    name: "Self",
    // route level code-splitting
    // this generates a separate chunk (about.[hash].js) for this route
    // which is lazy-loaded when the route is visited.
    component: () => import(/* webpackChunkName: "self" */ "../views/Self.vue"),
  },
];

const router = new VueRouter({
  routes,
});

export default router;
